<template>
    <div class="listcont">
      <div class="name">任务费用Top3</div>
      <el-table :data="taskList" size="mini" style="width:98%;margin: 0 auto;"
                :header-cell-style="{background:'#f7f7f7',color:'#fff','text-align':'center',height: '20px',fontSize:'14px'}"
                :row-style="{height: '26px'}">
          <el-table-column prop="brand" label="排名" align="center">
              <template slot-scope="scope">
                  <img :src="scope.row.brand" style="width: 27px;margin-top: 10px;margin-left: 11px;">
              </template>
          </el-table-column>
          <el-table-column prop="name" label="任务名称" align="center"></el-table-column>
          <el-table-column prop="time" label="运行时长" align="center"></el-table-column>
          <el-table-column prop="runs" label="运行次数" align="center"></el-table-column>
          <el-table-column prop="status" label="状态" align="center">
              <template slot-scope="scope">
                  <span v-if="scope.row.status===0" style="color:green">正常</span>
                  <span v-if="scope.row.status===1" style="color:red">停止</span>
              </template>
          </el-table-column>
          <el-table-column prop="cost" label="消费金额" align="center">
              <template slot-scope="scope">
                  ￥{{ scope.row.cost }}
              </template>
          </el-table-column>
      </el-table>
  </div>
</template>

<script>
  import IMGTOP1 from './image/TOP1.svg'
  import IMGTOP2 from './image/TOP2.svg'
  import IMGTOP3 from './image/TOP3.svg'
  export default {
    data () {
      return {
        taskList: [
          {
            brand: IMGTOP1,
            name: '工作流1',
            time: '1h56m53s',
            runs: '2',
            status: 0,
            cost: '0'
          },
          {
            brand: IMGTOP2,
            name: '工作流2',
            time: '1h56m53s',
            runs: '1',
            status: 0,
            cost: '0'
          },
          {
            brand: IMGTOP3,
            name: '工作流2',
            time: '1h56m53s',
            runs: '1',
            status: 1,
            cost: '0'
          }
        ]
      }
    }
  }
</script>

<style lang="scss" scoped>
</style>
